java remove non numeric characters from string

88

java remove non numeric characters from string -

myString.replaceAll("\\D", "")

java remove non numbers from string -

String str = "a12.334tyz.78x";
str = str.replaceAll("[^\\d.]", "");

Comments

Submit
0 Comments